home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Scene 96
/
Scene 96 International Edition (Zyklop Software) (Disc 2) (1997).iso
/
misc
/
coding
/
cp2dekit
/
samples
/
smptmode.cpp
< prev
next >
Wrap
C/C++ Source or Header
|
1996-12-29
|
1KB
|
67 lines
//***************************************************************************
//
// this file is (c) '94-'96 Niklas Beisert
//
// this file is part of the cubic player development kit.
// you may only use/modify/spread this file under the terms stated
// in the cubic player development kit accompanying documentation.
//
//***************************************************************************
//[general]
// link=smptmode
//[screen]
// defmodes=_cpiModeTextTest
// textmode example
#include <string.h>
#include "poutput.h"
#include "cpiface.h"
static void plDisplayHelp()
{
displaystr(5, 0, 0x09, " Hello World", 30);
}
static int plHelpKey(unsigned short key)
{
return 0;
}
static void hlpDraw()
{
cpiDrawGStrings();
plDisplayHelp();
}
static void hlpSetMode()
{
cpiSetTextMode(0);
}
static int hlpIProcessKey(unsigned short key)
{
switch (key)
{
case '!':
cpiSetMode("ttest");
break;
default:
return 0;
}
return 1;
}
static int hlpEvent(int ev)
{
return 1;
}
extern "C"
{
cpimoderegstruct cpiModeTextTest = {"ttest", hlpSetMode, hlpDraw, hlpIProcessKey, plHelpKey, hlpEvent};
}